/**
 * Copyright 2019 Inc.
 **/
package com.myz.service.memeber.web;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.client.RestTemplate;

/**
 * @author maoyz0621 on 19-3-13
 * @version: v1.0
 */
@RestController
public class ZipKinController {

    private static final String SERVICE_NAME = "SERVICE-ORDER";

    @Autowired
    private RestTemplate restTemplate;

    @GetMapping("/zipkin")
    public String zipkin() {
        return restTemplate.getForObject("http://" + SERVICE_NAME + "/order/order/hello", String.class);
    }
}
